n=eval(input("请输入阶乘的数:"))
for i in range(1,n):
    print(i)
    n=n*i
print(n)

